package singleton;
public class Single {
    Single(){}
    private static Single single = null;
    public static Single getInstance(){
        if(single==null){
            single=new Single();
        }
        return single;
    }
    private int num=0;
    public int say(){
        return ++num;
    }
}
